Previous Book Contents Book Index Next

Inside Macintosh: Mac OS 8 Toolbox Reference /
Chapter 7 - Finder Interface Reference / Finder Interface Functions
Manipulating Folder Descriptors /


GetFolderName

NEW WITH MAC OS 8

Gets the name of the specified folder.

pascal OSErr GetFolderName (
                     short vRefNum,
                     OSType foldType,
                     short *foundVRefNum,
                     Str63 name);
vRefNum
The volume reference number (or the constant kOnSystemDisk for the startup disk) of the volume containing the folder for which you wish the name to be identified.
foldType
A constant identifying the type of the folder for which you wish the name to be identified. See "Folder Type Constants".
foundVRefNum
On output, a pointer to the volume reference number for the volume containing the folder you specify in the foldType parameter.
name
On output, a string containing the title of the folder specified in the foldType and vRefNum parameters.
function result
A result code; see "Result Codes".
DISCUSSION
The GetFolderName function gets the name of the folder in the folder descriptor, not of the folder on the disk. The names may differ for a few special folders such as the System Folder. For relative folders, however, the actual name is always returned. You typically do not need to call this function.

SPECIAL CONSIDERATIONS
Before calling the GetFolderName function, you must pass the selector gestaltFindFolderAttr to the Gestalt function. If the gestaltFolderDescSupport bit is set, GetFolderName is available.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
8 JAN 1998